package com.meituan.catering.management.product.biz.model.request;

import com.meituan.catering.management.product.api.http.model.request.SearchProductHttpRequest;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.LinkedList;
import java.util.List;

import static java.lang.Boolean.FALSE;

/**
 * @author Believe
 * Date 2022/5/19 14:23
 */
@Data
public class SearchProductBizRequest {

    private Integer pageIndex = 1;

    private Integer pageSize = 10;

    private String name;

    private String unitOfMeasure;

    private Boolean enabled;

    private BigDecimal from;

    private BigDecimal to;

    private List<SortField> sortFields = new LinkedList<>();

    @Data
    public static class SortField {

        private String field;

        private String asc;

    }
}
